package com.cloud.mall.usr.service;

import com.cloud.mall.base.BaseResponse;
import com.cloud.mall.user.input.UmsResourceCategoryInpDTO;
import com.cloud.mall.user.output.UmsResourceCategoryOut;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.*;

import java.util.List;

@Api(tags = "资源分类管理接口")
@RequestMapping("/resourceCategory")
public interface UmsResourceCategoryService {
    @ApiOperation("查询所有后台资源分类")
    @GetMapping("/listAll")
    BaseResponse<List<UmsResourceCategoryOut>> listAll();

    @ApiOperation("添加后台资源分类")
    @PostMapping("/create")
    BaseResponse create(@RequestBody UmsResourceCategoryInpDTO umsResourceCategoryInpDTO);

    @ApiOperation("修改后台资源分类")
    @PostMapping("/update/{id}")
    BaseResponse update(@PathVariable Long id,
                               @RequestBody UmsResourceCategoryInpDTO umsResourceCategoryInpDTO);

    @ApiOperation("根据ID删除后台资源")
    @PostMapping("/delete/{id}")
    BaseResponse delete(@PathVariable Long id);

}
